home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d16 / winutil2.arc / TAME241.ARC / TAME.DOC < prev    next >
Text File  |  1990-11-01  |  46KB  |  1,322 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.                                     Tame
  14.                                 Release 2.41
  15.  
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.             Copyright 1988-1990 by PowerSoft and David G. Thomas
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.                              Table of Contents
  73.  
  74. Tame Users Guide .................................................. 1
  75.    Abstract ....................................................... 1
  76.    Copyright ...................................................... 1
  77.    Applications that definitely NEED Tame ......................... 2
  78.    Seeing if your applications need Tame .......................... 2
  79.    Running Tame ................................................... 3
  80.    If your program runs slower with Tame .......................... 4
  81.    Placing Tame in a batch file ................................... 4
  82.    Using Tame with other multi-taskers ............................ 4
  83.    Advanced Tame concepts ......................................... 5
  84.    Setting the frequency value .................................... 6
  85.    Setting default options ........................................ 7
  86.    The Tame status ................................................ 8
  87.  
  88. Tame Command Reference ............................................ 10
  89.    Task switching options ......................................... 10
  90.    Fine tuning for an application ................................. 11
  91.    Other options .................................................. 14
  92.  
  93. Multi-tasking Specifics ........................................... 16
  94.    DESQview ....................................................... 16
  95.    Double Dos ..................................................... 16
  96.    Omniview ....................................................... 16
  97.    Topview ........................................................ 16
  98.    VM/386 ......................................................... 16
  99.    Windows 3.0 and Windows/386 .................................... 16
  100.  
  101. Application Specifics ............................................. 17
  102.  
  103. Tame Upgrades ..................................................... 18
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.                               Tame Users Guide
  137.                                 Release 2.41
  138.  
  139.                    Copyright 1988,1989,1990 by PowerSoft
  140.                             and David G. Thomas
  141. Abstract
  142.  
  143. If you run  in a multi-tasking environment  such as DESQview, you  may have
  144. noticed that some programs  really slow down the whole system,  even though
  145. they seem to  be doing nothing  except waiting for  you to type  something.
  146. When I first encountered this type of program, I accepted it as part of the
  147. price that is paid for multi-tasking.  The Tame program proves that this is
  148. not the  case.  In  fact, the  Tame program  will significantly reduce  the
  149. overhead of many  programs, without hindering  their performance when  they
  150. really are working.
  151. Tame is designed to work with any DOS  based multi-tasking environment, and
  152. it contains  special  hooks  for use  in  DESQview, Double  Dos,  Omniview,
  153. VM/386, and Windows.  If you use Tame with another multi-tasker, please let
  154. me know whether or not it helps.
  155.  
  156. Copyright
  157.  
  158. This program is  copyrighted material.  It  may be freely distributed.   If
  159. you use  Tame  to speed  up  your applications,  please  contribute to  the
  160. author.  If you  send $20 or more,   you will receive a registered  copy of
  161. the latest version of the program, and also a printed  manual.  If you have
  162. any  questions  or  comments, I  may  be  reached  at  the  PowerSoft  BBS,
  163. (404) 928-9294.  Contributions should be mailed to the following address.
  164. David G. Thomas
  165. c/o PowerSoft
  166. P.O. Box  956338
  167. Duluth, GA 30136
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. Applications that definitely NEED Tame
  203. The following applications will continually poll the  keyboard, waiting for
  204. you to  press a  key.   Tame has been  proven to  significantly reduce  the
  205. overhead on  all these  applications.   For each  application listed  here,
  206. there are probably 100 more that need Tame!
  207.  
  208. See the end of this document for special options that may be desirable with
  209. these programs.
  210. Brief, by solution Systems
  211. EM4105
  212. Epsilon
  213. Harvard Graphics
  214. Kedit, by Mansfield Computing
  215. Lucid 3D, by PCSG
  216. Lotus 123, by Lotus Development Corp.
  217. Lotus Agenda, by Lotus Development Corp.
  218. Lotus Manuscript, by Lotus Development Corp.
  219. Microsoft editor, by Microsoft
  220. Norton Commander, by Peter Norton Computing
  221. PCBOARD, by Clark Development Company, Inc.
  222. Plan Perfect by Word Perfect Corp.
  223. Sidetalk, by Lattice
  224. Telix by Exis Inc.
  225. Tornado Notes by Micro Logic Corp
  226. Wildcat BBS Systems
  227. Word Perfect, by Word Perfect Corp.
  228. Word Perfect File Manager
  229. ZCOMM, by Omen Technology
  230.  
  231. Seeing if your applications need Tame
  232.  
  233. Any program  that uses CPU  cycles looking for  keyboard input needs  Tame.
  234. The best way to  see if a program does this  is to run a simple test.   You
  235. should test all  your favorite programs that  you spend time  entering data
  236. with.   This  includes  programs  such as  word  processors,  spreadsheets,
  237. editors, and DOS shells.
  238. One way to see if a  program needs tame is to use Tame to  run the program,
  239. and see what happens.    You may evaluate whether or not  Tame is effective
  240. by looking at  statistics generated with the  Tame command, or you  may use
  241. one of the many standard CPU benchmarks to test its effectiveness.
  242.  
  243. To test  a  program with  Tame, be  sure  you are  in  DESQview or  another
  244. supported multi-tasking system, and type the following command line.
  245.    TAME-RES
  246.  
  247. Now, run your  program, and work  in the program  for a little while,  then
  248. exit normally.  Type the following command line to obtain a summary of Tame
  249. activity.
  250.    TAME /STATUS
  251.  
  252. The displayed totals include the number of keyboard  polls that the program
  253. performed.  If this number small or zero, then Tame  may not be needed with
  254. the application.  With some extremely keyboard-hungry  programs, the number
  255. of keyboard polls can number into the thousands.
  256. A second, and more direct  way to test the effectiveness of Tame  is to run
  257. the application without Tame, and simultaneously run tame  with the /Geiger
  258. option in another task.  This is done with the following command.
  259.  
  260.    TAME-RES
  261.    TAME /GEIGER
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. You will hear ticks that indicate how loaded the CPU is.  If the ticks slow
  269. considerably when you are in  the application, it probably needs Tame.   If
  270. this is  the case, run  TAME-RES, and  re-run the  application.  The  ticks
  271. probably do not slow nearly as much as before.   This is because Tame keeps
  272. your background tasks running at nearly full speed, at  least while you are
  273. not actively needing the CPU.
  274. If you  don't trust the  Geiger counter that  is built  into Tame (you  may
  275. think that I  have "loaded the dice"),  try a more standard  CPU benchmark,
  276. such as Norton's System Information (SI) program.  To do this, load Tame in
  277. one task,  then execute your  program in that  same task.   Wait until  the
  278. application is idle, and waiting  for keyboard input.  Your program  is now
  279. being Tamed.   Now, switch to another  task and run the  benchmark program.
  280. Try this again without Taming  the first program (Either type TAME  /OFF or
  281. TAME /Uninstall).  If the  benchmark indicates that the CPU is  faster with
  282. Tame, then you know it  is helping.    Also, experiment  with which program
  283. is in the foreground  and which is in  the background.  This  experiment is
  284. necessary if you have set  the DESQview background task priority to  a very
  285. low number.  In any event, it is informative, since it indicates the amount
  286. of processing time  that the background  can get while  you are using  that
  287. application.
  288.  
  289. Running Tame
  290.  
  291. Tame is  composed  of a  resident  (TSR) program,  and  also a  controlling
  292. program.  The  resident portion of Tame  must be loaded before  running the
  293. main Tame program.  This  is done with the TAME-RES command.   For example,
  294. the following command lines will run Lotus 123 with Tame active.
  295.    TAME-RES
  296.    LOTUS
  297.  
  298. If you always want Tame  to be used, you may create a  batch file (possibly
  299. named RUNLOTUS.BAT), with the following command lines.
  300.    TAME-RES
  301.    LOTUS
  302.  
  303. A general  purpose variation of  this batch  file comes  with Tame, and  is
  304. named TAME-RUN.BAT.  Using the batch file, the  following command line will
  305. do the same thing as the previous examples.
  306.    TAME-RUN LOTUS
  307.  
  308. If you normally execute  the program with the DESQview "Open  Window" menu,
  309. you will need to modify the definition of the window.   To do this, use the
  310. "CP" (for Change Program) option of the "Open Window"  menu, and change the
  311. Program to TAME-RUN (or your custom batch file) and add what was previously
  312. the Program to the beginning of the command line parameters.
  313. The TAME-RES command has some of the functionality  of the TAME-RUN command
  314. built into it, with a few  restrictions.  It must run a .COM  or .EXE file,
  315. and the full path name of the program must be  specified.  For example, the
  316. following will Tame Lotus without using a batch file.
  317.  
  318.    TAME-RES C:\123\LOTUS.COM
  319. A variation of this syntax  is available when a "cloned" TAME-RES  is being
  320. used.  In this  case, you may preset  the Tame options that work  best with
  321. LOTUS, and automatically invoke LOTUS whenever the cloned  copy of TAME-RES
  322. is run.
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. If your program runs slower with Tame
  335. In some cases, the program may initially run slower (or "feel" choppy) with
  336. Tame installed.  This is frequently corrected by a few steps that will tune
  337. Tame  for the  application.    First,  try specifying  the  /Max  parameter
  338. (described below) to increase the number of polls allowed before Tame tries
  339. to switch  tasks.   A  good value  to try  is  /MAX:32,3.   In some  cases,
  340. changing /Max will have little effect if /KeyIdle is  also specified.  This
  341. is the case  with most well-behaved programs  that issue the  keyboard idle
  342. interrupt.
  343.  
  344. If the program prints very  slowly, try the /PARallel option.   This allows
  345. Tame to watch the  parallel port, and will  not invoke a task  switch while
  346. the port is being used.  For example, the following command lines should be
  347. used to run Word Perfect.
  348.    TAME-RES
  349.    TAME /PARALLEL
  350.    WP
  351.  
  352. Placing Tame in a batch file
  353.  
  354. If you run your application with a batch file, you may  like to add Tame to
  355. that batch file.  The only problem here is the fact that different programs
  356. like different Tame options, and also some programs will run other programs
  357. using  a DOS  Shell.    Tame has  special  options  for dealing  with  this
  358. situation.  The following batch  file will run Lotus 123, and  will restore
  359. the original Tame parameters before exiting.
  360.    :* It is assumed that TAME-RES
  361.    :* has already been loaded
  362.    :*
  363.    TAME /GETALL:TAME_123 /ON /MAX:3,0
  364.    123
  365.    TAME %TAME_123%
  366.    SET TAME_123=
  367.  
  368. Using Tame with other multi-taskers
  369.  
  370. Tame has  special hooks to  work very  effectively with DESQview,  Windows,
  371. Omniview, VM/386,  Double Dos and  Topview compatibles.   Tame may be  used
  372. with other multi-tasking environments,  but may not be quite  as effective.
  373. Also, you may need to  include a command line option to specify  the method
  374. that Tame should use to give idle time to the  other tasks.  The /KeySwitch
  375. method will be effective  with programs that are polling the  keyboard, and
  376. are not  polling any other  devices.  It  may not  be compatible with  some
  377. applications such as  communications programs.   The /HaltSwitch option  is
  378. compatible with   most programs, but may  not be effective,  depending upon
  379. the multi-tasking software being used.  In either case, run Tame as normal,
  380. and Tame  will  default to  the  /HaltSwitch task  switching  option.   The
  381. following command will run Lotus 123 in an environment that is not directly
  382. supported.
  383.    TAME-RES
  384.    LOTUS
  385.  
  386. If you use a multi-tasker that Tame is not effective with, I would like you
  387. to contact me.  I need to know some technical  data regarding how to detect
  388. and control the multi-tasker.  If it is feasible, I will add direct support
  389. for that multi-tasker to the Tame product.
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. Advanced Tame concepts
  401. Tame works by detecting when a program is continually polling the keyboard,
  402. and does its best to allow the multi-tasking software  to switch to another
  403. task.     It  detects  that a  program  is  polling the  keyboard  after  3
  404. successive keyboard polls  that occur within 1/18  of a second,  and during
  405. that time,  the program  does not  write  to the  screen or  issue any  DOS
  406. requests.   When the application  polls the  keyboard a fourth  consecutive
  407. time, Tame  checks one  last time for  a key-press,  and if  a key was  not
  408. pressed, it tries to switch the task.
  409.  
  410. This threshold  may  be increased  or  decreased using  the  /FREQUENCY:n,m
  411. option, where n is the main threshold.  The n  parameter specifies how many
  412. consecutive polls  that may occur  in a  single PC  clock tick before  Tame
  413. switches tasks.   There  are 18.2  clock ticks  per second,  so the  "true"
  414. frequency is actually  18.2 times the value  of n.  If  n is too  low, then
  415. Tame will switch tasks while  the application really is working.  If  it is
  416. too high then Tame may never switch tasks.  Unfortunately, a "one size fits
  417. all" value of n is  not possible, since it depends largely on  the speed of
  418. the machine, as well as the software that is being used.
  419. A reasonable value for n will be computed by Tame if you specify /Frequency
  420. with no parameters.  This  is done using a very crude formula  based on the
  421. speed of the CPU.  Since the CPU speed measurement  can take a few seconds,
  422. it is recommended that  this feature be used  only one time, and  an actual
  423. value is specified on subsequent runs.
  424.  
  425. The /FREQUENCY  option restricts the  time period that  Tame is allowed  to
  426. count keyboard polls.  This allows Tame to measure the  amount of real work
  427. that  the application  is  doing,  where  more  polls per  clock  tick  are
  428. associated with less actual work being done by the application.
  429. In some  instances, it  may not  be appropriate  to watch  the clock  while
  430. accumulating keyboard polls.   This is the  method that Tame used  prior to
  431. release 2.2, and is very  effective in many instances.  It also  happens to
  432. be much more easily tuned,  since the values do not normally depend  on the
  433. speed of  the machine.   This may  be done  by specifying /MAX:n,m  option,
  434. where n is the main threshold.   If n or m is much too low,  then Tame will
  435. switch tasks while the  application really is working.   If it is  too high
  436. then Tame will  not switch tasks until  long after the program  has settled
  437. into a  polling pattern,  reducing the  effectiveness of Tame  for a  brief
  438. period after  each key  is pressed.   Since  most programs  are capable  of
  439. polling 100 to 300 times per second, these parameters indirectly correspond
  440. to an "idle time limit" that is enforced by Tame.
  441.  
  442. After Tame detects excessive keyboard polling, a second  threshold is used.
  443. This threshold  is normally much  smaller than  the initial threshold,  and
  444. defaults to 2.  In effect, Tame will allow 3  keyboard polls, switch tasks,
  445. and then switch tasks on  every third successive keyboard poll until  a key
  446. is pressed, or the program does something besides poll  the keyboard.  This
  447. allows the first  threshold to be  raised to a  high number to  accommodate
  448. some programs, without significantly sacrificing the effectiveness of Tame.
  449. In most cases, the default of 2 for the second  threshold is adequate, abut
  450. it can be  lowered all the way  to zero if desired.   It may be  changed by
  451. specifying a second parameter of the /Max or /Frequency option.
  452. Some applications  will grab the  timer interrupt  that always occurs  18.2
  453. times per second.  In many cases, this interrupt takes  a lot of processing
  454. time, but really provides very little utility.  To avoid wasting processing
  455. time servicing the  timer interrupt, you  may prevent the application  from
  456. controlling the timer interrupt by specifying the /NOTIMER option.  In many
  457. cases, the  timer interrupt  may be  used to keep  a clock  running on  the
  458. screen.   This clock may  not be worth  much to you  when you consider  the
  459.  
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. amount of  processing time it  uses.  For  example, the following  commands
  467. will run the Brief  editor, (as long as  the auto-save feature of  Brief is
  468. disabled),   and  will gain  a  significant amount  of  processor time  for
  469. background processes.
  470.    TAME-RES
  471.    TAME /NOTIMER
  472.    B
  473.  
  474. Some applications spend  a lot of time  polling the system  clock, normally
  475. for the purpose  of an maintaining an  on-screen clock while it  is waiting
  476. for  other devices  to  have  a  character  ready.   The  /TIMEPOLL  option
  477. instructs Tame to treat the date and time query in  a manner similar to the
  478. keyboard poll,  and yield  the  time slice  after successive  date or  time
  479. queries.   The following  commands run  PCBOARD, which  keeps an  on-screen
  480. clock while waiting for the communications port.
  481.    TAME-RES
  482.    TAME /TIMEPOLL
  483.    PCBOARD
  484.  
  485. Most applications  will also  benefit  by specifying  /NoBackGround.   This
  486. option  is only  available  with DESQview,  and  should  not be  used  with
  487. communications programs.  When this  option is set, Tame will set  the task
  488. to not run in the background when it is polling.  This will completely shut
  489. down the  task until  it is  brought into the  foreground.   When the  task
  490. becomes active again, Tame will restore the task status,  to again allow it
  491. to run  in the  background.   This  automatic mode  switching is  extremely
  492. effective with most application programs.
  493.  
  494. Setting the frequency value
  495. Tame will  compute a  nominal value  for the frequency  threshold when  you
  496. specify /Frequency with  no parameters.   This is done  using a very  crude
  497. formula based  primarily on  the speed  of the CPU.   In  many cases,  this
  498. number is  adequate.  However,  when computing this  number, Tame does  not
  499. factor in any  special characteristics of  a specific application  program.
  500. To tune the  frequency for a  specific application, some real  measurements
  501. are needed.
  502.  
  503. Start by closing all tasks except a single task that  is at the DOS prompt.
  504. There  is  a  batch file  named  TAMETUNE.BAT  that  comes  with  the  Tame
  505. distribution archive.   Run  this batch  file and  supply the  name of  the
  506. application as an argument.  This batch file will simply clear Tame totals,
  507. and  then  run  the application.    Run  the  batch  file,  and  bring  the
  508. application to  its normal  input state  as soon as  is possible.   Let  it
  509. remain idle for at least  ten seconds.  During this time, Tame  is counting
  510. actual keyboard  polls.   After waiting  ten seconds, exit  the program  as
  511. quickly as possible.  Tame  will display a total number of polls  per clock
  512. tick that occurred while you were in the application.   Since you know that
  513. you were idle  during most of that  time, this number represents  that rate
  514. which the application is capable of polling the keyboard.   A good value to
  515. specify for the frequency parameter is between ¼ to ½  of the measured poll
  516. rate.
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532. Setting default options
  533. A special version  of TAME-RES with custom  options may easily  be created.
  534. This is done by specifying  the default options, and then using  the /CLONE
  535. option.   This creates  a new  program that  may be  used in  place of  the
  536. TAME-RES and  TAME  command combination.    The following  example  creates
  537. TAME-123.COM which defaults to the /NoBG and /FREQ:20,2 options.
  538.  
  539.    TAME-RES
  540.    TAME /NoBG /FREQ:20,2
  541.    TAME /CLONE:TAME-123
  542. Later, to  load Tame  resident and  run Lotus 123,  the following  commands
  543. could be used.
  544.  
  545.    TAME-123
  546.    123
  547. Alternatively, the following command could be used.
  548.  
  549.    TAME-123 C:\123\123.EXE
  550. Since this cloned version of Tame is set up with options specifically tuned
  551. for 123, then we may wish  to place the 123 command into the  new COM file.
  552. This is very convenient since it allows the Tamed version  of 123 to be run
  553. with a simple command.  This may be done using the following commands.
  554.  
  555.    TAME-RES
  556.    TAME /NoBG /FREQ:20,2
  557.    TAME /CLONE:123T,C:\123\123.EXE
  558. Note  that this  creates  a  modified  version of  TAME-RES.COM  that  will
  559. automatically run the 123 command - it does not modify  the 123.EXE file in
  560. any way.
  561.  
  562. Later, to run Tame and Lotus 123, the following command may be used.
  563.    123T
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598. The Tame status
  599. The /Status  option  prints many  statistics  that Tame  accumulates  while
  600. running.  These  statistics are interesting  to see, and  they may also  be
  601. useful for  tuning Tame  and the  multi-tasker.   This is  a sample  status
  602. report.
  603.  
  604.    TAME release 2.40  (Non-Registered version)
  605.    Copyright 1988-1990 by PowerSoft and David G. Thomas
  606.  
  607.    Tame Totals - Running in DESQview Task #2
  608.  
  609.         Key Polls      = 21,575
  610.         Time polls     = 21,262
  611.         Task switches  = 10,658
  612.         NoBG requests  =  1,043
  613.  
  614.         Elapsed Time   =  4,172 seconds
  615.         (Active=7  Polling=29  Input=0  Yielded=4,137)
  616.  
  617.         Poll rate      =      10 polls per second
  618.                                1 polls per tick
  619.                               66 polls per running tick
  620.  
  621.    Options: /ON /NoBackGround:10 /NoTimer /TimePoll /KeyPoll /NoSerial
  622.             /NoParallel /NoSYMbols /NoKeyIdle /Freq:20,2
  623. Key Polls       The total number  of times the program  polled to see  if a
  624.                 key has been pressed.
  625.  
  626. Time Polls      The total number of times the program called DOS requesting
  627.                 the current date or time.
  628. Task Switches   The number of times that Tame has forced a task switch.
  629.  
  630. NoBG Requests   The number of times that Tame instructed  DESQview run this
  631.                 program only  when  it is  in the  foreground,  not in  the
  632.                 background.    This number  can  sometimes  get  very  high
  633.                 because Tame has no way to know if the program is currently
  634.                 in the foreground, and, if it is, DESQview  will ignore the
  635.                 request.
  636. Elapsed Time    The total time  that Tame has been  running.  This  time is
  637.                 measured in seconds.  Tame does its best  to break the time
  638.                 down into  useful categories  which are shown  on the  next
  639.                 line.
  640.  
  641. Active          The amount  of time the  task was  active doing real  work.
  642.                 Due to limitations in the measurement capabilities of Tame,
  643.                 this may also include some time that was  actually spent in
  644.                 other  tasks.    This  can  happen  when  the  multi-tasker
  645.                 switches tasks  before Tame sees  a need  to, which is  the
  646.                 normal case  when  the  task is  working  very hard.    The
  647.                 measurement will be fairly accurate except  times when this
  648.                 task is working hard and other tasks are  also working very
  649.                 hard at the same time.
  650. Polling         The  amount  of  CPU  time  this  task  spent  polling  the
  651.                 keyboard.
  652.  
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664. Input           The amount of time this task spent waiting for input.  This
  665.                 is different  than  polling because  the task  specifically
  666.                 requested to  not  receive control  until  a key  has  been
  667.                 pressed.  This is  the normal case when waiting at  the DOS
  668.                 prompt, unless  Tame or another  program is monitoring  the
  669.                 idle interrupt (INT 28h).
  670. Yielded         The amount of  time that Tame  has yielded to other  tasks.
  671.                 It is a  measure of the  time difference between when  Tame
  672.                 switches  tasks, and  when  control  is returned  to  tame.
  673.                 Presumably, each  other task  has had a  time slice  during
  674.                 this time.
  675.  
  676. Poll Rate       This  is   the  ratio  of   total  polls  (Key-polls   plus
  677.                 Time-polls) that has occurred per second, per  tick and per
  678.                 running tick.  A tick is a measure that  is internal to the
  679.                 PC, and there are 18.21 ticks per second.  The total number
  680.                 of running ticks is a sum of active time plus polling time,
  681.                 multiplied  by 18.21  ticks  per  second.   The  polls  per
  682.                 active-tick is  an indicator  as  to how  fast the  program
  683.                 normally polls.
  684.  
  685.  
  686.  
  687.  
  688.  
  689.  
  690.  
  691.  
  692.  
  693.  
  694.  
  695.  
  696.  
  697.  
  698.  
  699.  
  700.  
  701.  
  702.  
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.                            Tame Command Reference
  731. Task switching options
  732.  
  733. The main purpose of Tame is to switch to another  task when it detects that
  734. the application  is  wasting time  polling the  keyboard.   With  DESQview,
  735. Windows,  Omniview,  Topview, VM/386  and  Double  Dos,  the  native  pause
  736. function is  used  to switch  tasks.   Since Tame  does  not have  specific
  737. support for other multi-taskers, you need to set  the task switching method
  738. for these other  multi-taskers.  The  following options specify the  method
  739. that Tame should use in order to switch tasks.
  740. ........
  741. /DESQVIEW       Use the native DESQview task switching method.
  742.  
  743. ........
  744. /DOUBLEDOS      Use the native Double DOS task switching method.
  745. ........
  746. /HaltSwitch     The /HaltSwitch option specifies that Tame should execute a
  747.                 HLT instruction when polling is detected.  This instruction
  748.                 has been found  to cause some multi-taskers  to immediately
  749.                 switch to another task.  This is the default task switching
  750.                 method when Tame does not recognize the multi-tasker.
  751.  
  752. ........
  753. /KeySwitch      The /KeySwitch option specifies that when the program polls
  754.                 the keyboard, Tame should  tell a white lie and say  that a
  755.                 key has been  pressed.  Most applications  will immediately
  756.                 read the key that Tame claimed was already  pressed.  Since
  757.                 it really was  not pressed, DOS will  wait for a key  to be
  758.                 pressed.  Most multi-taskers use this wait for  a key press
  759.                 as a queue to switch tasks.
  760.                 The /KeySwitch  option  could be  the  most effective  task
  761.                 switching method in  Tame, but it  will not work with  some
  762.                 applications.   Specifically,  it will  not  work with  any
  763.                 applications that poll devices other than  the keyboard, or
  764.                 with programs that occasionally flush  the keyboard buffer.
  765.                 It is also not effective in Windows/386.
  766.  
  767. ........
  768. /OMNIVIEW       Use the native Omniview task switching method.
  769. ........
  770. /TOPVIEW        Use the native Topview task switching method.
  771.  
  772. ........
  773. /VM386          Use the native  VM/386 task switching method  which happens
  774.                 to be the same as /HaltSwitch.
  775. ........
  776. /WINdows        Use the  native Windows  task  switching method.   This  is
  777.                 effective with Windows 3.0 and Windows/386.
  778.  
  779.  
  780.  
  781.  
  782.  
  783.  
  784.  
  785.  
  786.  
  787.  
  788.  
  789.  
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796. Fine tuning for an application
  797. The default  Tame options  will  work well  with most  programs.   However,
  798. portions of some programs will run slower with Tame.   With other programs,
  799. Tame may not  reduce the CPU  overhead, even though  the program polls  the
  800. keyboard.  The  following options may be  specified in order to  adjust the
  801. effects of Tame on a specific application program.
  802.  
  803. ........
  804. /INT15          This option  improves the effectiveness  of Tame with  some
  805.                 programs, but it does not work on all computer systems.  In
  806.                 fact, with some machines, it will lock up the system.
  807.                 This option may be turned off by specifying /NoINT15.
  808.  
  809. ........
  810. /NoBG:n         This option can be  very effective with DESQview,  and will
  811. /FGonly:n       be ignored if  another multi-tasking system is  being used.
  812.                 When this  option is  specified, Tame will  patiently do  a
  813.                 normal task switch  n times.   If no activity is  detected,
  814.                 then it  will  instruct DESQview  to  temporarily run  this
  815.                 program only  while it is  in the foreground.   As soon  as
  816.                 this  program  is brought  to  the  foreground,  Tame  will
  817.                 instruct DESQview  to  again allow  it  to execute  in  the
  818.                 background.
  819.                 This  option  is extremely  effective  in  preventing  idle
  820.                 background processes  from slowing  performance of  working
  821.                 processes.  However, since its net effect  is to completely
  822.                 stop the  task (if  it is  in the background),  it is  very
  823.                 sensitive to how well the /Frequency or /Max parameters are
  824.                 tuned.  It also will not be effective with background tasks
  825.                 which may  remain idle  for a  period of  time, and  become
  826.                 active  based  on  external  events   (e.g.  communications
  827.                 program).
  828.  
  829.                 This option may  be turned off  by specifying /NoFGonly  or
  830.                 /BackGround.
  831. ........
  832. /Freq:n,m       This option may need to be used in order to fine-tune Tame.
  833.                 It sets n as  the number of consecutive keyboard  polls per
  834.                 clock tick that are acceptable before Tame decides that the
  835.                 program is doing no other work except polling the keyboard.
  836.                 This number defaults to 3.  If this number is too low, then
  837.                 Tame may switch tasks while the program  is really working.
  838.                 Specifying /Frequency with no parameters will allow Tame to
  839.                 compute a reasonable value  based on the speed of  the CPU.
  840.                 Since some application programs poll the keyboard at a high
  841.                 rate (even while they are working), so this option does not
  842.                 always provide advantages over /Max.
  843.  
  844. ........
  845. /KeyIdle:n      This option works well with many programs that are gracious
  846.                 enough to  inform DOS  that it  is somewhat  idle while  it
  847.                 polls the keyboard.  When Tame detects this idle situation,
  848.                 it will temporarily lower the /Max  or /Frequency threshold
  849.                 to n.   This seems  to work  especially well with  programs
  850.                 that always inform  DOS when it  is idle, and the  standard
  851.                 threshold can be  set to -1,  telling Tame to never  switch
  852.                 tasks unless  the application  confirms that  it is  really
  853.                 idle.
  854.  
  855.  
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.                 Beginning with  DESQview release 2.26,  this option is  not
  863.                 recommended for tasks that  spend a lot of time at  the DOS
  864.                 prompt.   This is  because DESQview detects  the fact  that
  865.                 Tame is watching  the idle interrupt,  and when at the  DOS
  866.                 prompt, DESQview goes out of its way to  make sure the idle
  867.                 interrupt  is   called,   wasting  some   processing   time
  868.                 unnecessarily.  This option is still  very effective inside
  869.                 some programs,  and  the problem  only  occurs at  the  DOS
  870.                 prompt.
  871.                 This option may be turned off by specifying /NoKeyIdle.
  872.  
  873. ........
  874. /NoKeyPoll      This option instructs Tame  to not look at  keyboard polls.
  875.                 This  may  be useful  with  some  programs  that  poll  the
  876.                 keyboard whether they are working or not, but they poll the
  877.                 date or time only during keyboard input.   In this case, it
  878.                 may be best to switch tasks based on  the /TimePoll switch,
  879.                 and ignore all key polls.
  880.                 This option may be reversed with /KeyPoll.
  881.  
  882. ........
  883. /Max:n,m        This option may need to be used if the application seems to
  884.                 run  slower  with  Tame.   It  sets  n  as  the  number  of
  885.                 consecutive polls that  are acceptable before  Tame decides
  886.                 that the program is simply polling while waiting for input.
  887.                 If this number is too low, then Tame may switch tasks while
  888.                 the program  is really working.   If  you suspect that  the
  889.                 program (or a particular  aspect of the program)  is slower
  890.                 with Tame, raise this number.  Parameters as  high as a few
  891.                 thousand may  be  needed  in some  cases.   Note  that  the
  892.                 /Frequency parameter  may be  used  in place  of /Max,  and
  893.                 /Frequency is generally more effective.
  894.                 The second number may  optionally be specified in  order to
  895.                 change the number  of consecutive polls  that Tame uses  to
  896.                 switch  tasks after  it  has  already determined  that  the
  897.                 program is in a polling mode.
  898.  
  899.                 Either n or m  may be -1, which indicates that  Tame should
  900.                 not cause a task switch based upon polling alone.  This  is
  901.                 effective  with  programs  that  issue  the  keyboard  idle
  902.                 interrupt while  they are  polling the  keyboard, and  will
  903.                 prevent  Tame  from   switching  tasks  from   intermittent
  904.                 keyboard polls.
  905.                 In some cases, changing  /Max will have no  apparent effect
  906.                 when /KeyIdle  is also specified.   This  is the case  with
  907.                 most well-behaved  programs  that issue  the keyboard  idle
  908.                 interrupt.
  909.  
  910. ........
  911. /NoTimer        This option  prevents the  application from processing  the
  912.                 timer interrupt  that is  normally  issued by  the PC  18.2
  913.                 times per second.  This option may disable some features of
  914.                 the program, and should  be used with caution.  It  is very
  915.                 useful with programs that  use a lot of CPU  processing the
  916.                 timer interrupt, and accomplish little.
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.                 This option works  by intercepting the programs  request to
  929.                 be called by the timer interrupt.    The program assumes it
  930.                 will be called on  a regular basis by the  timer interrupt,
  931.                 but, since Tame  did not pass this  request on to  DOS, the
  932.                 program will never be called by the interrupt.
  933.                 This option may be turned off by specifying /Timer.
  934.  
  935. ........
  936. /PARallel       This option  instructs Tame  to watch  BIOS level  parallel
  937.                 port accesses, and if the port is frequently being used, do
  938.                 not allow  a  task switch.   This  option  is not  normally
  939.                 needed except  with programs that  bypass DOS in  accessing
  940.                 the printer.   It  should be  used only when  it is  really
  941.                 needed.
  942. ........
  943. /SERial         This option instructs Tame to watch BIOS  level serial port
  944.                 accesses, and if the port is frequently being  used, do not
  945.                 allow a task  switch.  This  option is not normally  needed
  946.                 except with programs  that use the  serial port (e.g.  comm
  947.                 programs, bulletin boards, etc...).  It should be used only
  948.                 when it is really needed.
  949.  
  950. ........
  951. /TimePoll       This option instructs  Tame to consider  a request for  the
  952.                 current time to be similar to a keyboard  poll.  This works
  953.                 well  with programs  that  constantly update  an  on-screen
  954.                 clock.  This option  may have no effect when  /KeySwitch is
  955.                 specified.   It  is recommended  that  the second  /Max  or
  956.                 /Frequency  parameter  have  a  minimum  value  of  2  when
  957.                 /TimePoll is specified.
  958.                 This option may be turned off by specifying /NoTimePoll.
  959.  
  960.  
  961.  
  962.  
  963.  
  964.  
  965.  
  966.  
  967.  
  968.  
  969.  
  970.  
  971.  
  972.  
  973.  
  974.  
  975.  
  976.  
  977.  
  978.  
  979.  
  980.  
  981.  
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994. Other options
  995. ........
  996. /CLeaR          Zero the totals that Tame displays on the status report.
  997.  
  998. ........
  999. /CLONE:file     This command  will make a  special version of  TAME-RES.COM
  1000.                 that  has customized  default  parameters.   The  currently
  1001.                 active defaults will be placed into the cloned program.  In
  1002.                 all cases,  the /CLONE  option should be  the only  command
  1003.                 line option  that  is specified.    The cloned  program  is
  1004.                 specified with the file value, and should be named TAME-xxx
  1005.                 where xxx is an abbreviation for the application name.  The
  1006.                 new TAME-xxx.COM may  be run in  place of the  TAME-RES.COM
  1007.                 and TAME.EXE duo that is frequently needed when starting up
  1008.                 a new task.
  1009. ........
  1010. /CLONE:f,c      This command  will make a  special version of  TAME-RES.COM
  1011.                 that  has  customized default  parameters,  and  also  will
  1012.                 automatically run a specific command.  The currently active
  1013.                 defaults will be  placed into the  cloned program.  In  all
  1014.                 cases, the /CLONE  option should be  the only command  line
  1015.                 option that is specified.  The new COM may  be run in place
  1016.                 of the TAME-RES.COM, TAME.EXE and  program combination that
  1017.                 is frequently  needed when starting  up a  new task.   Note
  1018.                 that f is  the name of the  new COM file (without  the .COM
  1019.                 suffix), and  c is the  full path  name of  the EXE or  COM
  1020.                 style command that is to be run.
  1021.  
  1022. ........
  1023. /Geiger:p,t,f   This option starts up  a sound that is similar to  a Geiger
  1024.                 counter.  This sound speeds up when the system is idle, and
  1025.                 slows as other  tasks demand CPU resources.   It is  a very
  1026.                 useful tool for monitoring the effectiveness of Tame, since
  1027.                 it  allows  you to  monitor  the  amount  of  CPU  that  an
  1028.                 application will use with and without Tame.
  1029.                 There are three optional parameters that  may be specified.
  1030.                 The p parameter sets amount of time (in  1/18 second units)
  1031.                 between eich Geiger tick.  The default value  is one, which
  1032.                 will make about  18 ticks per second.   Setting it  to zero
  1033.                 will give a tick each time this task gets a time slice, but
  1034.                 the zero  setting requires TAME-RES  to be  loaded.  The  t
  1035.                 parameter sets  the amount of  time each  tick takes.   The
  1036.                 default is based on the speed of the CPU.   When t is zero,
  1037.                 a faint tick may still be heard.  The  f parameter sets the
  1038.                 frequency of the ticks, in Hertz.
  1039.  
  1040. ........
  1041. /GETALL:var     Get the  current Tame  parameters, and place  them into  an
  1042.                 environment variable named var.    This option  is designed
  1043.                 for use  in a  batch  file, in  order to  restore the  Tame
  1044.                 parameters after running a program.
  1045.                 This option has been tested with DOS versions  3.1 and 3.3,
  1046.                 but it will not work with DOS 3.2.  I  hope to correct this
  1047.                 problem with  a  future  release.   If  you are  running  a
  1048.                 multi-tasker with DOS 2.0, I strongly recommend you upgrade
  1049.                 to DOS  3.x so you  can take  advantage of the  protections
  1050.                 provided with the SHARE command.
  1051.  
  1052.  
  1053.  
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060. ........
  1061. /OFF            Temporarily disable Tame, but leave it in  memory for later
  1062.                 use.
  1063. ........
  1064. /ON             Enable Tame task switching.  Tame is on by default.
  1065.  
  1066. ........
  1067. /Status         Display a summary report.  The summary  includes the number
  1068.                 of task  switches that  were initiated by  Tame, the  total
  1069.                 number of  keyboard calls  that the  application made,  and
  1070.                 also a summary of the current options.
  1071. ........
  1072. /Uninstall      Remove the resident portion of Tame from memory.
  1073.  
  1074.  
  1075.  
  1076.  
  1077.  
  1078.  
  1079.  
  1080.  
  1081.  
  1082.  
  1083.  
  1084.  
  1085.  
  1086.  
  1087.  
  1088.  
  1089.  
  1090.  
  1091.  
  1092.  
  1093.  
  1094.  
  1095.  
  1096.  
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102.  
  1103.  
  1104.  
  1105.  
  1106.  
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.                           Multi-tasking Specifics
  1127. DESQview
  1128.  
  1129. Tame will automatically detect  the presence of DESQview, and will  use its
  1130. native task switching method.   Tame has been tested with DESQview versions
  1131. 2.01 through 2.26, and appears to work well with all versions.
  1132. If you set the /Frequency parameter correctly, the  /NoBackGround option is
  1133. strongly recommended with most application programs.  It  will prevent idle
  1134. background programs from affecting performance.
  1135.  
  1136. Tame is most effective with DESQview when QEMM and DESQview are combined on
  1137. an 80386 based PC.  Tame  will also be effective on a machine  with an 8088
  1138. or 80286 and  should be used  with many programs  that do not have  special
  1139. DESQview loaders.
  1140.  
  1141. Double Dos
  1142. Tame will automatically detect the presence of Double Dos, and will use its
  1143. native task switching method.
  1144.  
  1145. Omniview
  1146.  
  1147. Tame cannot  tell  the difference  between DESQview  and  Omniview.   After
  1148. loading TAME-RES, run TAME with the /OMNIVIEW option.
  1149.  
  1150. Topview
  1151. After loading TAME-RES, run TAME with the /TOPVIEW option.
  1152.  
  1153. VM/386
  1154.  
  1155. Tame does  not specifically  detect VM/386.   After  loading TAME-RES,  you
  1156. should run TAME with the /VM386 option.
  1157.  
  1158. Windows 3.0 and Windows/386
  1159. Tame will automatically  detect the presence of  Windows, and will  use its
  1160. native task switching method.   When the /FREQ option is used,  the optimal
  1161. value may vary drastically from the value used with other multi-taskers.
  1162.  
  1163. Tame can be much more effective than the idle detection  that is built into
  1164. Windows.  When using Tame, it is best to disable Windows idle detection for
  1165. each window that uses  Tame.  Also, if  you had previously set a  window to
  1166. run with a low background  priority, you may wish to raise it  and let Tame
  1167. decide when it really needs the CPU.
  1168.  
  1169.  
  1170.  
  1171.  
  1172.  
  1173.  
  1174.  
  1175.  
  1176.  
  1177.  
  1178.  
  1179.  
  1180.  
  1181.  
  1182.  
  1183.  
  1184.  
  1185.  
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192.                            Application Specifics
  1193. Most applications  may be  run with  Tame without  any special  parameters.
  1194. However, for best results, certain command line parameters may be desirable
  1195. for some  applications.  The  following table  represents the benefits  and
  1196. effects of recommended  command line parameters  for each program when  run
  1197. under  DESQview.   In  most  cases,  tuning  Tame so  that  /FREQuency  and
  1198. /NoBackGround may be used  is strongly recommended.  Results may  vary with
  1199. other multi-taskers.
  1200.  
  1201.  Application    Recommended options Results &
  1202.  Program                            Side effects
  1203.  Brief          (use defaults)       About 75% of the CPU overhead is
  1204.                                       eliminated.
  1205.  Brief          /NoTimer /KeyIdle    Nearly all the CPU overhead is
  1206.                                       eliminated.
  1207.                                      On screen clock and auto-save
  1208.                                       feature are disabled.
  1209.  Info Select    /NoKeyPoll           Nearly all the CPU overhead is
  1210.                 /TimePoll             eliminated
  1211.  Kedit          (use defaults)       Nearly all of the CPU overhead is
  1212.                                       eliminated.
  1213.  Lotus 123      (use defaults)       Nearly all the CPU overhead is
  1214.                                       eliminated.
  1215.  Lotus Agenda   (use defaults)       Nearly all the CPU overhead is
  1216.                                       eliminated.
  1217.  Lotus          /NoTimer /Max:-1     Nearly all the CPU overhead is
  1218.  Manuscript     /KeyIdle              eliminated.
  1219.  Lucid 3D       (use defaults)       Nearly all the CPU overhead is
  1220.                                       eliminated.
  1221.  Microsoft      (use defaults)       Nearly all the CPU overhead is
  1222.  Editor                               eliminated.
  1223.  Norton         (use defaults)       Nearly all the CPU overhead is
  1224.  Commander                            eliminated.
  1225.                                      Tame will also cover programs that
  1226.                                       are run by the shell.
  1227.  PCBOARD        /TimePoll            About 75% of the CPU overhead is
  1228.                                       eliminated.
  1229.  Quick C        /NoTimer             Nearly all of the CPU overhead is
  1230.                                       eliminated.
  1231.                                      Side effects (if any) of /NoTimer
  1232.                                       have not been determined.
  1233.  Sidetalk       (use defaults)       About 75% of the CPU overhead is
  1234.                                       eliminated.
  1235.  Tornado Notes  /NoKeyPoll           Nearly all the CPU overhead is
  1236.                 /TimePoll             eliminated
  1237.  Word Perfect   /Parallel            About 75% of the CPU overhead is
  1238.                                       eliminated.
  1239.  ZCOMM          /Serial              About 75% of the CPU overhead is
  1240.                                       eliminated.
  1241.  
  1242.  
  1243.  
  1244.  
  1245.  
  1246.  
  1247.  
  1248.  
  1249.  
  1250.  
  1251.  
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258.                                Tame Upgrades
  1259. The latest  release of Tame  will be continuously  posted on the  PowerSoft
  1260. bulletin board system at  (404) 928-9294.  Also, since Tame  is distributed
  1261. as a shareware program, the latest release will normally  be available on a
  1262. local bulletin board.
  1263.  
  1264. If you are a  registered user, you have  paid for a perpetual  license, and
  1265. may register  each new  version of  Tame using  a utility  program that  is
  1266. provided with your  registration kit.  This  utility may be  run completely
  1267. from the  command  line.   For  example, the  following  command line  will
  1268. register Fred Smith if the password of ABCD is correct.
  1269.    TAME-REG "Fred Smith" ABCD
  1270.  
  1271. If you prefer, the  registration program may be run without  specifying any
  1272. arguments, and you will be prompted for the information.
  1273.  
  1274.  
  1275.  
  1276.  
  1277.  
  1278.  
  1279.  
  1280.  
  1281.  
  1282.  
  1283.  
  1284.  
  1285.  
  1286.  
  1287.  
  1288.  
  1289.  
  1290.  
  1291.  
  1292.  
  1293.  
  1294.  
  1295.  
  1296.  
  1297.  
  1298.  
  1299.  
  1300.  
  1301.  
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308.  
  1309.  
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.